<div class="bjui-pageHeader">
    <div class="pull-right">
        <button class="btn-default" data-icon="plus" title="添加管理员" data-toggle="tooltip" data-placement="left" onclick="createDialog('{:U("Forms/admin")}', '添加管理员', 'admin')"></button>
        <button class="btn-default" data-icon="refresh" onclick="$.CurrentNavtab.navtab('refresh')"></button>
    </div>
    <form id="pagerForm" data-toggle="ajaxsearch" data-loadingmask="true" action="{:U('index')}" method="post">
        <input type="hidden" name="pageSize" value="{:I('param.pageSize')}" />
        <input type="hidden" name="pageCurrent" value="{:I('param.pageCurrent')}" />
        <input type="hidden" name="orderField" value="{:I('param.orderField')}" />
        <input type="hidden" name="orderDirection" value="{:I('param.orderDirection')}" />
        <div class="bjui-searchBar">
            <label>名称:</label>
            <input type="text" name="name" value="{:I('name')}"  />
            <button type="submit" class="btn-default" data-icon="search">查询</button>
            <a class="btn btn-orange" href="javascript:;" data-toggle="reloadsearch" data-clear-query="true" data-icon="undo">清空查询</a>
        </div>
    </form>
</div>
<div class="bjui-pageContent tableContent">
    <table class="table table-bordered table-hover table-striped table-top" data-selected-multi="false">
        <thead>
            <tr>
                <th width="26">ID</th>
                <th>用户名</th>
                <th>所属角色</th>
                <th>Email地址</th>
                <th>加入时间</th>
                <th>最近登录</th>
                <th>状态</th>
                <th width="100">操作</th>
            </tr>
        </thead>
        <tbody>
        <volist name="list" id="vo">
        <tr>
            <td>{$vo.id}</td>
            <td>{$vo.username}</td>
            <td>{$vo.rolename}</td>
            <td>{$vo.email}</td>
            <td>{$vo.reg_time}</td>
            <td>{$vo.login_time}</td>
            <td>
                <if condition="$vo.status eq '0'">
					<a href="{:U('Forms/update_admin',array('id'=>$vo['id']))}" data-toggle="doajax" data-type="get" data-confirm-msg="确定要禁用这个帐号?">正常</a>
				<else/>
					<a href="{:U('Forms/update_admin',array('id'=>$vo['id']))}" data-toggle="doajax" data-type="get" data-confirm-msg="确定要启用这个帐号?">已禁用</a>
				</if>
            </td>
            <td>
                <a href="{:U('Forms/reset_admin',array('id'=>$vo['id']))}" class="btn btn-green"  data-toggle="doajax" data-confirm-msg="你确定要重置该管理员的密码吗?" data-type="get">重置密码</button>
                <a href="{:U('Forms/del_admin',array('id'=>$vo['id']))}" class="btn btn-red" data-toggle="doajax" data-confirm-msg="要删除管理员吗?" data-type="get">删</a>
            </td>
        </tr>
        </volist>
        </tbody>
    </table>
</div>
<include file="Common/footer" ftype="page" />